home *** CD-ROM | disk | FTP | other *** search
/ QRZ! Ham Radio 8 / QRZ Ham Radio Callsign Database - Volume 8.iso / pc / files / misc / monoband.bqs / MONOBAND.BAS
BASIC Source File  |  1996-06-25  |  9KB  |  176 lines

  1. 10 CLS
  2. 20 LOCATE 4,11:PRINT CHR$(201);:FOR I = 1 TO 58:PRINT CHR$(205);:NEXT I:PRINT CHR$(187)
  3. 30 LOCATE 5,11:PRINT CHR$(186);:LOCATE 5,70:PRINT CHR$(186)
  4. 40 LOCATE 6,11:PRINT CHR$(186);:LOCATE 6,70:PRINT CHR$(186)
  5. 50 LOCATE 7,11:PRINT CHR$(186);:LOCATE 7,70:PRINT CHR$(186)
  6. 60 LOCATE 8,11:PRINT CHR$(186);:LOCATE 8,70:PRINT CHR$(186)
  7. 70 LOCATE 9,11:PRINT CHR$(186);:LOCATE 9,70:PRINT CHR$(186)
  8. 80 LOCATE 10,11:PRINT CHR$(186);:LOCATE 10,70:PRINT CHR$(186)
  9. 90 LOCATE 11,11:PRINT CHR$(186);:LOCATE 11,70:PRINT CHR$(186)
  10. 100 LOCATE 12,11:PRINT CHR$(186);:LOCATE 12,70:PRINT CHR$(186)
  11. 110 LOCATE 13,11:PRINT CHR$(186);:LOCATE 13,70:PRINT CHR$(186)
  12. 120 LOCATE 14,11:PRINT CHR$(186);:LOCATE 14,70:PRINT CHR$(186)
  13. 130 LOCATE 15,11:PRINT CHR$(186);:LOCATE 15,70:PRINT CHR$(186)
  14. 140 LOCATE 16,11:PRINT CHR$(186);:LOCATE 16,70:PRINT CHR$(186)
  15. 150 LOCATE 17,11:PRINT CHR$(186);:LOCATE 17,70:PRINT CHR$(186)
  16. 160 LOCATE 18,11:PRINT CHR$(186);:LOCATE 18,70:PRINT CHR$(186)
  17. 170 LOCATE 19,11:PRINT CHR$(200);:FOR I = 1 TO 58:PRINT CHR$(205);:NEXT I:PRINT CHR$(188)
  18. 180 LOCATE 7,23:PRINT "Originally Written for the Atari"
  19. 190 LOCATE 8,36:PRINT "by"
  20. 200 LOCATE 18,17:PRINT "Compiled using the Microsoft Basic Compiler V2.0"
  21. 210 LOCATE 5,28:PRINT "MONOBAND ANTENNA DESIGN"
  22. 220 LOCATE 9,27:PRINT "Alan Hoffmaster WA3EKL"
  23. 230 LOCATE 14,19:PRINT "With a lot of help from Alan's Wife, Susan"
  24. 240 LOCATE 13,28:PRINT "Edward Mester WA3HQX"
  25. 250 LOCATE 12,36:PRINT "by"
  26. 260 LOCATE 11,23:PRINT "Converted to the IBM-PC format"
  27. 270 LOCATE 16,22:PRINT "THIS SOFTWARE IS IN THE PUBLIC DOMAIN"
  28. 280 FOR I = 1 TO 15000:NEXT I
  29. 290 CLS:LOCATE 10,27:PRINT"Mono Band Antenna Design":FOR I=1 TO 4000:NEXT I
  30. 300 DIM C$(3),B$(4)
  31. 310 CLS:LOCATE 10,25:INPUT"Do you wish instructions (Y/N)";C$
  32. 320 IF C$="N" OR C$="n" OR C$="NO" OR C$="no" THEN 630
  33. 330 CLS:LOCATE 10,1
  34. 340 PRINT"This program was written using the formulas published in 1980 Ham Radio";
  35. 350 PRINT"magazine and written by W2PV who proved mathematically and experimentally that";
  36. 360 PRINT"antenna element resonate frequency length is not a simple calculation";
  37. 370 PRINT"especially when tapered elements are involved.":FOR I=1 TO 15000:NEXT I
  38. 380 CLS:LOCATE 10,27:PRINT"Mechanical Recomendations":FOR I=1 TO 4000:NEXT I
  39. 390 PRINT"20 Meter boom should be 3 or 4 inch diameter aluminum irrigation pipe depending on length."
  40. 400 PRINT"Elements should be tapered segments from 1 1/4 inches to 1/2 inch diameters of  6061 R6 tubing or equivalent."
  41. 410 DIM I$
  42. 420 LOCATE 16,22:PRINT"To continue instructions press RETURN";:INPUT I$
  43. 430 CLS:LOCATE 10,1:PRINT"10-15 Meter booms should be made of 2 inch aluminum irrigation pipe."
  44. 440 PRINT"Elements should be tapered from 7/8 inches to 5/8 inch diameters of 6061 T6     seamless tubing or equivalent.":FOR I=1 TO 15000:NEXT I
  45. 450 CLS:LOCATE 10,27:PRINT"Electrical recomendations":FOR I=1 TO 4000:NEXT I
  46. 460 CLS:LOCATE 10,1:PRINT"For maximum front to back ratio, use a 1/4 wavelength boom on a 3 element beam."
  47. 470 PRINT"Use a 3/4 wavelength boom on a 4,5 or 6 element beam.
  48. 480 PRINT"Equally space all elements along the boom reguardless of length."
  49. 490 PRINT"For a good 2 element beam, use a boom length of .150 wavelength."
  50. 500 PRINT"For a good 3 element beam, use a boom length of .300 wavelength."
  51. 510 LOCATE 16,22:PRINT"To continue press RETURN";:INPUT I$
  52. 520 CLS:LOCATE 10,1:PRINT"IMPORTANT-All total length dimensions will be element half lengths,";
  53. 530 PRINT"meaning the length of the element measured from the boom out to the tip of the";
  54. 540 PRINT"measured from the boom out to the tip of the element. Enter element segment";
  55. 550 PRINT"will be assembled, starting with the largest diameter segment (which crosses";
  56. 560 PRINT"over the boom) to the smallest diameter segment at the element tip. The"
  57. 570 PRINT"object is to adjust the original segment lengths so that the total equivalent"
  58. 580 PRINT"length is equal to or very close to the normalized length for the particular"
  59. 590 PRINT"element you are working on.":LOCATE 19,22:PRINT"To continue press RETURN";:INPUT I$
  60. 600 CLS:LOCATE 10,1:PRINT"When to computer asks you for information, enter in the information then press"
  61. 610 PRINT"return. Nothing will happen until you press return. If nothing happens"
  62. 620 PRINT"immediately, wait. The computer may be thinking.":LOCATE 14,22:PRINT"To continue press RETURN";:INPUT I$
  63. 630 CLS:LOCATE 5,1:PRINT"Enter central design frequency in MHZ";:INPUT CDF
  64. 640 RL=11811.024#/CDF:' RESONATE LENGTH IN INCHES
  65. 650 LOCATE 7,1:PRINT"Enter number of antenna elements 2,3,4,5 or 6";:INPUT P
  66. 660 IF P<2 OR P>6 THEN 650
  67. 670 LOCATE 9,1:PRINT"Enter boom diameter";:INPUT BD
  68. 680 BC=(BD/2)*.0625:REM BOOM CORRECTION
  69. 690 LOCATE 11,1:PRINT"Enter number of antenna segments";:INPUT N
  70. 700 X=0:DIM L((N-1)),D((N-1)),F((N-1))
  71. 710 FOR E=0 TO (N-1)
  72. 720 L(E)=0:D(E)=0:F(E)=0
  73. 730 NEXT E:REM clear arrays
  74. 740 PRINT:PRINT"Enter (in inches) length of segment";:INPUT A
  75. 750 L(X)=A
  76. 760 PRINT:PRINT"Enter (in inches) diameter of segment";:INPUT B
  77. 770 D(X)=B
  78. 780 GOSUB 1720
  79. 790 X=X+1:' STEPPING DATA INTO L ARRAY
  80. 800 IF X=N THEN 820
  81. 810 GOTO 740:' ENTERING IN SUCCESSIVE LENGTHS AND DIAMETERS
  82. 820 FOR EE=0 TO (N-1)
  83. 830 TD=TD+D(EE)
  84. 840 NEXT EE
  85. 850 AD=TD/N
  86. 860 GOSUB 1340
  87. 870 GOSUB 1660
  88. 880 T=0:G=0:' CLEAR TOTAL
  89. 890 FOR Y=0 TO (N-1)
  90. 900 T=T+L(Y):' ADD SEGMENT LENGTHS
  91. 910 PRINT L(Y)" inches long";D(Y);" inches dia."
  92. 920 NEXT Y
  93. 930 PRINT:PRINT T;" inches=total original length"
  94. 940 O1=0:O2=0:W=0
  95. 950 RO1=AD/(2*RL):' =RADIUS OF CENTER SEGMENT
  96. 960 D1=D(G)
  97. 970 RO2=D1/(2*RL):' =RADIUS OF SUCCESSIVE SEGMENTS
  98. 980 G=G+1:' STEPPING THRU SEGMENT DIAMETERS
  99. 990 K1=1/RO1
  100. 1000 K2=1/RO2
  101. 1010 M=((43.03*(LOG(K2)/LOG(10))-32))/((43.03*(LOG(K1)/LOG(10))-32))
  102. 1020 O2=(L(W)*1.57079632#)/T+O1:' O2 IN RADIANS
  103. 1030 FO=(SIN(2*O2)-SIN(2*O1))/((2*O2)-(2*O1))
  104. 1040 O1=O2
  105. 1050 SA=((M+1/M)/2+(M-1/M)*FO/2)*L(W)
  106. 1060 F(W)=SA:' PLACE EQUIVALENT LENGTHS INTO F ARRAY
  107. 1070 W=W+1:' STEPPING THRU F ARRAY
  108. 1080 IF W=N THEN 1100
  109. 1090 GOTO 950:' LOOP TO CALCULATE EACH SEGMENT LENGTH
  110. 1100 S=0:' CLEAR EQUIVALENT LENGTH TOTAL
  111. 1110 FOR Z=0 TO (N-1)
  112. 1120 S=S+F(Z):' ADD EQUIVALENT LENGTHS IN F ARRAY
  113. 1130 NEXT Z
  114. 1140 PRINT S;" inches=total equivalent length"
  115. 1150 PRINT:PRINT"Do you wish to change a segment length? (Y/N)";:INPUT B$
  116. 1160 IF B$="N" OR B$="n" THEN 1280
  117. 1170 PRINT"Enter number of segments you wish to change, counting from the boom out.";:INPUT V
  118. 1180 IF V<1 THEN 1170
  119. 1190 IF V>N THEN 1170
  120. 1200 PRINT"Enter new segment length (in inches)";:INPUT U
  121. 1210 L(V-1)=U
  122. 1220 GOSUB 1660
  123. 1230 GOTO 880
  124. 1240 PRINT P;" Element beam at ";CDF;" MHZ"
  125. 1250 FOR TT=0 TO (N-1)
  126. 1260 PRINT L(TT);" inches long",D(TT);" inches dia."
  127. 1270 NEXT TT
  128. 1280 PRINT:PRINT"Write down element lengths appearing on the screen and add the following correc-";
  129. 1290 PRINT"tions to the outer most element for final length."
  130. 1300 PRINT:PRINT"on 20 Meters add ";BC+.66;" inches"
  131. 1310 PRINT"on 15 Meters add ";BC+.44;" inches"
  132. 1320 PRINT"on 10 Meters add ";BC+.24;" inches"
  133. 1330 END
  134. 1340 DIM A(13),B(13)
  135. 1350 FOR H=0 TO 13
  136. 1360 A(H)=0:B(H)=0
  137. 1370 NEXT H:' CLEAR A AND B ARRAYS
  138. 1380 A(0)=.49366:A(1)=.49801:A(2)=.49185:A(3)=.49994:A(4)=.49528:A(5)=.4705
  139. 1390 A(6)=.48963:A(7)=.479:A(8)=.4804:A(9)=.48028:A(10)=.469:A(11)=.46319
  140. 1400 A(12)=.45232:A(13)=.44811
  141. 1410 DIM R(6),DE(6),DR(6)
  142. 1420 FOR Q=0 TO 6
  143. 1430 R(Q)=0:DE(Q)=0:DR(Q)=0
  144. 1440 NEXT Q:' CLEAR R,DE,DR
  145. 1450 IF AD=.875 THEN 1600
  146. 1460 RA1=.875/(2*RL)
  147. 1470 RA2=AD/(2*RL)
  148. 1480 KK1=1/RA1
  149. 1490 KK2=1/RA2
  150. 1500 FOR J=0 TO 13
  151. 1510 FR1=(1-((10.7575*(LOG(KK1)/LOG(10)))-8)^-1)/(2*A(J))
  152. 1520 XX1=((215.15*(LOG(KK1)/LOG(10)))-160)*((1/FR1)-FR1)
  153. 1530 AA=XX1/((215.15*(LOG(KK2)/LOG(10)))-160)
  154. 1540 FR2=(-AA+((AA^2)+4)^.5)/2
  155. 1550 B(J)=(1-((10.7575*(LOG(KK2)/LOG(10)))-8)^-1)/(2*FR2)
  156. 1560 NEXT J
  157. 1570 R(2)=B(0):R(3)=B(1):R(4)=B(2):R(5)=B(3):R(6)=B(4):DE(2)=B(5):DE(3)=B(6)
  158. 1580 DE(4)=B(7):DE(5)=B(8):DE(6)=B(9):DR(3)=B(10):DR(4)=B(11):DR(5)=B(12):DR(6)=B(13)
  159. 1590 GOTO 1620
  160. 1600 R(2)=A(0):R(3)=A(1):R(4)=A(2):R(5)=A(3):R(6)=A(4):DE(2)=A(5):DE(3)=A(6):DE(4)=A(7):DE(5)=A(8):DE(6)=A(9)
  161. 1610 DR(3)=A(10):DR(4)=A(11):DR(5)=A(12):DR(6)=A(13)
  162. 1620 RST=(RL*R(P))/2:' REFLECTOR NORMALIZED 1/2 LENGTH
  163. 1630 DEST=(RL*DE(P))/2:' DRIVEN ELEMENT NORMALIZED 1/2 HALF LENGTH
  164. 1640 DRST=(RL*DR(P))/2:' DIRECTORS NORMALIZED 1/2 LENGTH
  165. 1650 RETURN
  166. 1660 CLS:PRINT P;" Element beam at ";CDF;" MHZ"
  167. 1670 PRINT:PRINT RST;" Inches = normalized reflector 1/2 length"
  168. 1680 PRINT DEST;" Inches = normalized driven element 1/2 length"
  169. 1690 PRINT DRST;" Inches = normalized directors 1/2 length":PRINT
  170. 1700 RETURN
  171. 1720 PRINT:PRINT P;" Element beam at ";CDF;" MHZ"
  172. 1730 FOR AB=0 TO (N-1)
  173. 1740 PRINT L(AB);" Inches long",D(AB);" Inches diameter."
  174. 1750 NEXT AB
  175. 1760 RETURN
  176. at